package com.example.demo_redis_test.configuration;

import com.example.demo_redis_test.configuration.domain.ConfigA;
import com.example.demo_redis_test.configuration.domain.ConfigB;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class TestConfiguration {
    public static void main(String[] args) {
        ApplicationContext ctx = new AnnotationConfigApplicationContext(ConfigBConfiguration.class);
        ConfigA configA= ctx.getBean(ConfigA.class);
        ConfigB configB= ctx.getBean(ConfigB.class);
        System.out.println(configA.tostring());
        System.out.println(configB);
    }
}
